# For the benefit of emacs users: -*- shell-script -*-
#
#  _ _____ _     _            _
# (_)___ /| |__ | | ___   ___| | _____
# | | |_ \| '_ \| |/ _ \ / __| |/ / __|
# | |___) | |_) | | (_) | (__|   <\__ \
# |_|____/|_.__/|_|\___/ \___|_|\_\___/

align=center
separator=false
color=#FFFFF0
separator_block_width=40
markup=pango

[home]
command=df -h /home | awk 'FNR==2 { gsub(/[A-Za-z]/, ""); printf "%i<span color=\"#50fa7b\"> GB</span>\n", $3 }'
interval=3
label=<span color="#50fa7b"> </span>
border=#50fa7b
border_top=0
border_right=0
border_bottom=2
border_left=0


[root]
command=df -h /home | awk 'FNR==2 { gsub(/[A-Za-z]/, ""); printf "%i/%i<span color=\"#f1fa8c\"> GB</span>\n", $2, $4 }'
interval=3
label=<span color="#f1fa8c">⛁ </span>
border=#f1fa8c
border_top=0
border_right=0
border_bottom=2
border_left=0


[memory]
command=free --giga | awk 'FNR==2{ printf "%i<span color=\"#ff79c6\"> GB</span>\n", $7 }'
interval=2
label=<span color="#ff79c6"> </span>
border=#ff79c6
border_top=0
border_right=0
border_bottom=2
border_left=0


[volume]
command=~/.config/i3/i3blocks/audio
interval=1
label=<span color="#FFFF00"> </span>
border=#FFFF00
border_top=0
border_right=0
border_bottom=2
border_left=0


[network]
command=~/.config/i3/i3blocks/network
interval=1
label=<span color="#00ffbb">🌐︁ </span>
border=#00ffbb
border_top=0
border_right=0
border_bottom=2
border_left=0

[time]
command=date '+%H:%M' | awk '{ printf "<span color=\"#ff00ff\">%s</span>\n", $1}'
interval=60
label=<span color="#ff00FF">⏰︁ </span>
border=#ff00ff
border_top=0
border_right=0
border_bottom=2
border_left=0


[date]
command=date '+%a %Y.%m.%d ' | awk '{ printf "<span color=\"#ebff91\">%s %s %s</span>\n", $1, $2, $3}'
interval=100
label=<span color="#EBFF91">📅 </span>
border=#EBFF91
border_top=0
border_right=0
border_bottom=2
border_left=0




# [mediaplayer]
# command=playerctl metadata --format "{{ artist }} <span color=\"#bd93f9\">-</span> {{ title }}"
# interval=2
# label=<span color="#bd93f9"> </span>
# border=#bd93f9
# border_top=0
# border_right=0
# border_bottom=1
# border_left=0


# [wifi]
# command=iwgetid -r | tr '\n' ' ' && grep $(iwgetid -m | awk '{ printf "%s", $1 }') /proc/net/wireless | awk '{ printf "%i%\n", int($3 * 100 / 70) }'
# instance=wlp11s0f3u1
# interval=5
# label=<span color="#ff79c6"> </span>
# border=#ff79c6
# border_top=0
# border_right=0
# border_bottom=0
# border_left=0


# [battery]
# interval=2
# color=#ff5555
# border=#ff5555
# border_top=3
# border_right=0
# border_bottom=0
# border_left=0

#
# [cpu_stats]
# command=sar -u 1 1 | awk 'FNR == 5 { printf "%04.1f<span color=\"#ff5555\">%</span>", (100 - $8) } ' && sensors | awk '{ if ($1 == "CPU" && $2 == "Temperature:") { gsub(/[+°C]/, "") ; printf " %i<span color=\"#ff5555\">°C</span>\n", $3 } }'
# interval=2
# label=<span color="#ff5555"><b>CPU: </b></span>
# border=#ff5555
# border_top=0
# border_right=0
# border_bottom=1
# border_left=0


# [gpu_stats]
# command=nvidia-smi --query-gpu=utilization.gpu --format=csv,noheader,nounits | awk '{ printf "%02i<span color=\"#ffb86c\">%</span>", $0}' && nvidia-smi --query-gpu=temperature.gpu --format=csv,noheader,nounits | awk '{ printf " %i<span color=\"#ffb86c\">°C</span>\n", $0}'
# label=<span color="#ffb86c"><b>GPU: </b></span>
# interval=2
# border=#ffb86c
# border_top=1
# border_right=0
# border_bottom=0
# border_left=0

